package com;

import com.service.HintNumService;
import com.service.HintSharesService;
import com.service.SharesDataService;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;


@SpringBootTest
@RunWith(SpringRunner.class)
public class DataDemo {


    @Autowired
    private SharesDataService sharesDataService;

    @Autowired
    private HintNumService hintNumService;

    @Autowired
    private HintSharesService hintSharesService;

    /**
     * 获取最近一年左右的日k数据
     */
    @Test
    public void getDataByYear() {
        sharesDataService.getDataByYear();
    }

    /**
     * 获取跟涨的数据
     */
    @Test
    public void getZdfShares() {
        sharesDataService.getZdfShares();
    }

    /**
     * 前9.30
     * 前10.30
     * 前11点
     * 每天前10点提示的股有多少
     * 冲高回落的股有多少
     * 大涨的股有多少
     */
    @Test
    public void getTsData() {
        sharesDataService.getTsData();
    }

    /**
     * 判断涨跌
     */
    @Test
    public void jData() {
        sharesDataService.jData();
    }

    /**
     * 获取创业板指
     */
    @Test
    public void getsz() {
        sharesDataService.getsz();
    }

    /**
     * 提示数据
     */
    @Test
    public void getnum() {
        hintNumService.saveNum();
    }

    /**
     * 提示数据测试
     */
    @Test
    public void getIntit() {
        hintSharesService.highzdf(null);
    }
}
